package vip.xiaonuo.device.modular.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import vip.xiaonuo.device.modular.entity.DevDict;
import vip.xiaonuo.device.modular.entity.DevFile;

import java.util.List;

/**
 * @author 墨塵
 * @since 2023/5/17
 */
public interface DevDictMapper extends BaseMapper<DevDict> {

    @Select("SELECT DICT_LABEL, DICT_VALUE FROM DEV_DICT WHERE PARENT_ID = ( SELECT ID FROM DEV_DICT WHERE DICT_VALUE = #{dictValue} ) and DELETE_FLAG='NOT_DELETE' order by SORT_CODE")
    List<DevDict> getList(@Param("dictValue") String dictValue);
}
